import java.util.Scanner;

public class buyTicket {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入您要购买的票价：");
        int ticket = sc.nextInt();
        System.out.println("请输入购票月份：");
        int month = sc.nextInt();
        System.out.println("请输入购票等级：");
        int rank = sc.nextInt();
        buyTicket(ticket, month, rank);
    }

    public static void buyTicket(int ticket, int month, int rank) {
        if(month < 5 && month > 10) {
            if(rank == 0){
                System.out.println("淡季，经济舱票价为：" + (ticket * 0.65)+ "元" );
            }
            else if(rank == 1){
                System.out.println("淡季，商务舱票价为：" + (ticket * 0.7)+ "元" );
            }
        }
        else if (month >= 5 && month <= 10) {
            if(rank == 0){
                System.out.println("旺季，经济舱票价为：" + (ticket * 0.85)+ "元" );
            }
            else if(rank == 1){
                System.out.println("旺季，商务舱票价为：" + (ticket * 0.9)+ "元" );
            }
        }
    }
}
